home *** CD-ROM | disk | FTP | other *** search
/ Loadstar 35 / 035.d81 / time zone (.txt) < prev    next >
Commodore BASIC  |  2022-08-26  |  5KB  |  188 lines

  1. 10 :
  2. 20 :
  3. 30 ifx=0thenx=1:gosub2000:load"time zone.lnk",8,1
  4. 40 ifx=1thenx=2:load"text.3.o",8,1
  5. 50 ifx=2thenx=3:load"unpacker",8,1
  6. 60 :
  7. 65 poke249,224:poke250,204
  8. 66 poke251,0:poke252,64
  9. 67 :
  10. 70 gosub240
  11. 80 gosub260
  12. 81 poke828,0:poke829,39:poke830,0:poke831,24
  13. 82 poke255,2:poke253,0:poke254,0:sys51462:rem title
  14. 83 sys49161,"[204][207][193][196][211][212][193][210] presents:",4,0,0
  15. 84 sys49161,"([195]) 1987",2,23,1
  16. 85 sys49161,"[195]64 version by [193]lan [199]ardner",7,24,0
  17. 86 sys49161,"[208][210][197][211][211] [193] [203][197][217]",24,23,0:sys51459:ag=3.4
  18. 87 poke828,0:poke829,39
  19. 88 poke830,0:poke831,24
  20. 90 :
  21. 180 :
  22. 185 poke198,0:wait198,1:poke198,0
  23. 190 ag=3.4:dim uct$(25),ct$(25),lt$(25)
  24. 200 gosub240:gosub260
  25. 201 ag=3.4:gosub1130
  26. 210 sys49161,"[213]se [195][213][210][211][207][210] keys and [210][197][212][213][210][206] to select a",1,1,1
  27. 211 sys49161,"time zone, or press '[209]' to [209][213][201][212].",1,2,1
  28. 220 gosub440
  29. 230 :
  30. 240 poke255,0:poke253,0:poke254,0:sys51462:return
  31. 250 :
  32. 260 poke255,1:poke253,0:poke254,6:sys51462:return
  33. 390 :
  34. 400 sys49161,"[208]acific  [205]ountain  [195]entral   [197]astern",1,5,0
  35. 401 :
  36. 410 :
  37. 420 :
  38. 421 :
  39. 430 :
  40. 440 b=0:es$=chr$(81):rt$=chr$(29):lf$=chr$(157):cr$=chr$(13)
  41. 441 be$=chr$(7):up$=chr$(145):dn$=chr$(17):gosub590
  42. 450 poke198,0:wait198,1:getk$
  43. 460 ifk$=up$thenk$=rt$
  44. 470 ifk$=dn$thenk$=lf$
  45. 480 ifk$="[208]"ork$="p"thenb=0:gosub590:goto450
  46. 490 ifk$="[205]"ork$="m"thenb=1:gosub590:goto450
  47. 500 ifk$="[195]"ork$="c"thenb=2:gosub590:goto450
  48. 510 ifk$="[197]"ork$="e"thenb=3:gosub590:goto450
  49. 520 if(k$<>es$andk$<>"[209]")thenifk$<>rt$thenifk$<>lf$thenifk$<>cr$then450
  50. 530 ifk$=rt$thenb=b+1-(4*abs(b=3)):gosub590
  51. 540 ifk$=lf$thenb=b-1+(4*abs(b=0)):gosub590
  52. 550 ifk$=es$ork$="[209]"thengosub610
  53. 560 ifk$=cr$thenf=z(b):gosub670
  54. 570 goto450
  55. 580 :
  56. 590 :
  57. 591 mo=1:ifb=0thenmo=0
  58. 592 sys49161,"[208]acific",2,4,mo
  59. 593 mo=1:ifb=1thenmo=0
  60. 594 sys49161,"[205]ountain",10,4,mo
  61. 595 mo=1:ifb=2thenmo=0
  62. 596 sys49161,"[195]entral",20,4,mo
  63. 597 mo=1:ifb=3thenmo=0
  64. 598 sys49161,"[197]astern",28,4,mo
  65. 599 return
  66. 600 :
  67. 610 poke255,3:poke254,10:poke253,10:sys51462:ag=3.4
  68. 620 sys49161,"[209]uit for sure?",15,11,0
  69. 622 sys49161,"([217] or [206])",18,12,0
  70. 625 poke198,0:wait198,1:getk$
  71. 630 ifk$="[217]"ork$="y"then1550
  72. 640 ifk$<>"[206]"thenifk$<>"n"then625
  73. 650 gosub260:return
  74. 660 :
  75. 670 poke255,3:poke254,10:poke253,10:sys51462:ag=3.4
  76. 680 sys49161,"<[211]>tandard or <[196]>aylight",10,11,0
  77. 681 sys49161," [211]avings [212]ime?",14,12,0
  78. 690 poke198,0:wait198,1:getch$
  79. 700 ifch$=es$then650
  80. 710 ifch$="[211]"orch$="s"thenb1=1
  81. 720 ifch$="[196]"orch$="d"thenb1=2:f=f+1
  82. 730 ifb1<>1andb1<>2then670
  83. 740 gosub770
  84. 750 run190
  85. 760 :
  86. 770 gosub240
  87. 780 sys49161,"[213]niversal time coordinated ([199][205][212])",2,2,1:ag=3.34
  88. 781 sys49161,"to "+tn$(b,b1)+" chart",2,3,1
  89. 800 sys49161,"[215][207][210][203][201][206][199]....",12,12,1
  90. 810 forn=0to23
  91. 820 uct=n
  92. 830 lt=uct+f
  93. 840 iflt<0thenlt=lt+24
  94. 850 iflt>23thenlt=abs(lt-24)
  95. 860 gosub1240
  96. 870 uct$(n)=mid$(str$(uct),2)+"00 "
  97. 880 iflen(uct$(n))<5thenuct$(n)="0"+uct$(n)
  98. 890 lt$(n)=mid$(str$(lt),2)+"00"
  99. 900 iflen(lt$(n))<4thenlt$(n)="0"+lt$(n)
  100. 910 iflen(ct$(n))<5thenct$(n)=" "+ct$(n)
  101. 920 nextn
  102. 930 sys49161,"[213][212][195]              "+t$(b,b1),4,5,1
  103. 932 sys49161,"---              ---",4,6,1
  104. 940 forn=0to12
  105. 950 sys49161,uct$(n)+" -------  "+lt$(n)+"  "+ct$(n),3,n+7,1
  106. 960 next
  107. 970 sys49161,"[208][210][197][211][211] [193] [203][197][217]",13,23,1:poke198,0:wait198,1:geta$
  108. 980 gosub240
  109. 990 sys49161,"[213]niversal time coordinated ([199][205][212])",2,2,1:ag=3.34
  110. 991 sys49161,"to "+tn$(b,b1)+" chart",2,3,1
  111. 1010 sys49161,"[213][212][195]              "+t$(b,b1),4,5,1
  112. 1011 sys49161,"---              ---",4,6,1
  113. 1020 forn=12to23
  114. 1030 sys49161,uct$(n)+" -------  "+lt$(n)+"  "+ct$(n),3,n+7-12,1
  115. 1040 next
  116. 1050 sys49161,"[212][201][205][197] [196][201][198][198][197][210][197][206][195][197]: "+str$(f)+" [200][207][213][210][211].",3,20,1
  117. 1060 sys49161,"[208][210][197][211][211] [193] [203][197][217]",13,23,1:poke198,0:wait198,1:getk$
  118. 1061 poke255,3:poke253,10:poke254,10:sys51462:ag=3.34
  119. 1080 sys49161,"[196]o you want a",15,11,0
  120. 1082 sys49161,"[208][210][201][206][212][207][213][212] ([217]/[206])?",14,12,0
  121. 1085 poke198,0:wait198,1:getk$:ifk$<>"y"andk$<>"n"andk$<>"[217]"andk$<>"[206]"then1085
  122. 1090 ifk$="[217]"ork$="y"thengosub1310:k$="[206]"
  123. 1100 ifk$<>"[206]"thenifk$<>"n"thenprintbe$;:goto1070
  124. 1110 return
  125. 1120 :
  126. 1130 tn$(0,1)="[208]acific [211]tandard [212]ime":t$(0,1)="[208][211][212]"
  127. 1140 tn$(0,2)="[208]acific [196]aylight [212]ime":t$(0,2)="[208][196][212]"
  128. 1150 tn$(1,1)="[205]ountain [211]tandard [212]ime":t$(1,1)="[205][211][212]"
  129. 1160 tn$(1,2)="[205]ountain [196]aylight [212]ime":t$(1,2)="[205][196][212]"
  130. 1170 tn$(2,1)="[195]entral [211]tandard [212]ime":t$(2,1)="[195][211][212]"
  131. 1180 tn$(2,2)="[195]entral [196]aylight [212]ime":t$(2,2)="[195][196][212]"
  132. 1190 tn$(3,1)="[197]astern [211]tandard [212]ime":t$(3,1)="[197][211][212]"
  133. 1200 tn$(3,2)="[197]astern [196]aylight [212]ime":t$(3,2)="[197][196][212]"
  134. 1210 z(0)=-8:z(1)=-7:z(2)=-6:z(3)=-5
  135. 1220 return
  136. 1230 :
  137. 1240 ct=lt:ap$="[193][205]"
  138. 1250 ifct>12thenct=ct-12:ap$="[208][205]"
  139. 1260 ifct=12thenap$="[206][207][207][206]"
  140. 1270 ifct=0thenct=12:ap$="[205][201][196][206][201][199][200][212]"
  141. 1280 ct$(n)=str$(ct):iflen(ct$(n))<3thenct$(n)=ct$(n)+" "
  142. 1285 ct$(n)=ct$(n)+" "+ap$
  143. 1290 return
  144. 1300 :
  145. 1310 poke255,3:poke253,10:poke254,10:sys51462:ag=3.34
  146. 1320 sys49161,"[212]urn on your printer",12,11,0
  147. 1322 sys49161,"and press [210][197][212][213][210][206]",14,12,0
  148. 1330 sys49161,"[208]ress '[209]' to cancel.",12,13,0
  149. 1340 poke198,0:wait198,1:getk$
  150. 1350 ifk$=es$ork$="[209]"thenreturn
  151. 1360 ifk$<>cr$then1310
  152. 1370 open15,4,15:close15:ifst=0then1380
  153. 1372 poke255,3:poke253,10:poke254,10:sys51462:ag=3.34
  154. 1374 sys49161,"[208][210][201][206][212][197][210] [206][207][212] [207][206]-[204][201][206][197]",12,12,0:fordl=1to1000:next:goto1310
  155. 1380 open4,4,7:cmd4
  156. 1382 sp$="                                        "
  157. 1390 print
  158. 1400 print"             [213]niversal [212]ime [195]oordinated ([199][205][212]) to"
  159. 1401 print"                "tn$(b,b1)" chart.         "
  160. 1402 print"                 -------------------------------"
  161. 1410 print"    [213][212][195]           "t$(b,b1)"                  [213][212][195]";
  162. 1411 print"           "t$(b,b1)"           "
  163. 1420 print"    ---           ---                  ---           ---"
  164. 1421 print"           "
  165. 1430 forn=0to12
  166. 1440 print"   "uct$(n)"     "lt$(n)"    "ct$(n);
  167. 1441 printright$(sp$,abs(12-len(ct$(n))));
  168. 1450 print"     ";
  169. 1460 ifn=12thenprint"[212]ime difference: "f" hours.";:goto1490
  170. 1470 printuct$(n+12)"     "lt$(n+12)"    "ct$(n+12);
  171. 1480 printright$(sp$,abs(8-len(ct$(n+12))));
  172. 1490 print"   "
  173. 1500 next
  174. 1510 :
  175. 1520 print#4:close4
  176. 1530 return
  177. 1540 :
  178. 1550 open15,8,15,"r0:hello connect=hello connect":input#15,er:close15:print"[147]"
  179. 1552 print"[147]";:ifer<>63thensys51459:end
  180. 1554 open15,8,15,"i0":close15
  181. 1556 sys51459
  182. 1560 load"hello connect",8
  183. 1570 end
  184. 2000 :
  185. 2002 poke53281,0:poke53280,5
  186. 2004 print"[147]   [206]ow  entering  the  [212]ime  [218]one..."
  187. 2006 return
  188.